Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove some closure compiler hacks #8437

Merged
merged 3 commits into from
Apr 11, 2019
Merged

Remove some closure compiler hacks #8437

merged 3 commits into from
Apr 11, 2019

Conversation

kripken
Copy link
Member

@kripken kripken commented Apr 11, 2019

The hacks for GL are not just ugly, but also bad for code size in some cases, it turns out (apparently closure will not optimize as much in their presence).

This is a step towards #8421, the changes for which end up causing closure to emit worse code if not for this PR.

Copy link
Collaborator

@sbc100 sbc100 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems reasonable.

@@ -753,6 +753,7 @@ var LibraryGLFW = {

event.preventDefault();

#if '$FS' in addedLibraryItems
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting, I didn't know about this "preprocessor syntax"

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, we made it possible to run arbitrary JS in the preprocessor, I think this was a few months ago.

@kripken kripken merged commit 7cae063 into incoming Apr 11, 2019
@kripken kripken deleted the reoder2 branch April 11, 2019 23:06
VirtualTim pushed a commit to VirtualTim/emscripten that referenced this pull request May 21, 2019
The hacks for GL are not just ugly, but also bad for code size in some cases, it turns out (apparently closure will not optimize as much in their presence).

This is a step towards emscripten-core#8421, the changes for which end up causing closure to emit worse code if not for this PR.
VirtualTim added a commit to VirtualTim/emscripten that referenced this pull request May 23, 2019
VirtualTim added a commit to VirtualTim/emscripten that referenced this pull request May 23, 2019
kripken added a commit that referenced this pull request Dec 16, 2019
…JS libraries we have not yet included anything from libraries, so we should not read addedLibraryItems
kripken added a commit that referenced this pull request Dec 20, 2019
* Revert part of #8437 - the glfw part was invalid, as when processing JS libraries we have not yet included anything from libraries, so we should not read addedLibraryItems

* fix deps. fixes #10004

* ifdef FS code in glfw
petersalomonsen pushed a commit to petersalomonsen/emscripten that referenced this pull request Dec 22, 2019
…e#10058)

* Revert part of emscripten-core#8437 - the glfw part was invalid, as when processing JS libraries we have not yet included anything from libraries, so we should not read addedLibraryItems

* fix deps. fixes emscripten-core#10004

* ifdef FS code in glfw
belraquib pushed a commit to belraquib/emscripten that referenced this pull request Dec 23, 2020
The hacks for GL are not just ugly, but also bad for code size in some cases, it turns out (apparently closure will not optimize as much in their presence).

This is a step towards emscripten-core#8421, the changes for which end up causing closure to emit worse code if not for this PR.
belraquib pushed a commit to belraquib/emscripten that referenced this pull request Dec 23, 2020
…e#10058)

* Revert part of emscripten-core#8437 - the glfw part was invalid, as when processing JS libraries we have not yet included anything from libraries, so we should not read addedLibraryItems

* fix deps. fixes emscripten-core#10004

* ifdef FS code in glfw
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants